<!DOCTYPE html>
<html>
<#include "../head.html">
    <body>
    <table class="mc">
        <tr>
            <td class="mc-l">
                <!--左侧导航---{-->
                <div id="navPanelContainer">
                    <div class="system-logo cd"></div>
                    <!--管理员信息---{-->
                    <#include "../adminInfo.html">
                        <!--管理员信息---}-->
                        <div class="nav-wrap">
                            <#include "left.html">
                        </div>
                </div>
                <!--左侧导航---}-->
            </td>
            <td class="mc-m">
                <div class="navToggle"></div>
            </td>
            <td class="mc-r">
                <!--顶部导航---{-->
                <#include "../topNav.html">
                    <!--顶部导航---}-->

                    <!--面包屑导航---{-->
                    <#assign moduleName="查看所有帐户">
                        <#include "banner.html">
                            <!--面包屑导航---}-->

                            <!--工具栏--{-->
                            <div id="toolbar" class="clearfix">
                                <div class="toolbor-module export">
                                    <input type="button" onclick="exportxls()" value="导出报表" class="input-button export-btn"/>
                                    <#if param??&&param.status??>
                                        <#assign status=(param.get("status"))?number >
                                            <#else>
                                                <#assign status=-1>
                                    </#if>
                                </div>
                                <div class="toolbor-module search">    
                                    <input type="button" value="搜索"  class="input-button" onclick="sousuo();">
                                </div>
                                <div class="toolbor-module search">
                                    <input type="text" name="username" id="username" value="请输入用户名" data-value="请输入用户名" class="search-value">
	                                <!-- v1.6.7.1 RDPROJECT-402 zza 2013-11-07 start -->
                                    <input type="text" name="realname" id="realname" value="请输入真实姓名" data-value="请输入真实姓名" class="search-value">
	                                <!-- v1.6.7.1 RDPROJECT-402 zza 2013-11-07 end -->
                                </div>
                            </div>
                            <!--工具栏--}-->

                            <div id="main" class="clearfix">
                                <form action="" method="post">
                                    <table class="data-list">
                                        <tr class="header">
                                            <td>ID</td>
                                            <td>用户名</td>
                                            <td>真实姓名</td>
                                            <td>总余额</td>
                                            <td>可用余额</td>
                                            <td>冻结金额</td>
                                            <td>待收金额</td>
                                            <td>待还金额</td>
                                            <td>净资产</td>
                                            <!-- v1.6.7.1 RDPROJECT-467 2013-11-19 start -->
											<td>净值标待还</td>
											<!-- v1.6.7.1 RDPROJECT-467 2013-11-19 end -->
                                            <!-- v1.6.6.2 RDPROJECT-297 liukun 2013-10-22 begin -->
                                            <td>操作</td>
                                            <!-- v1.6.6.2 RDPROJECT-297 liukun 2013-10-22 end -->
                                        </tr>
                                        <#list list as item>
                                            <tr class="s">
                                                <td>${(item.id!0)?c}</td>
                                                <td>${item.username!}</td>
                                                <td>${item.realname!}</td>
                                                <td>${(item.total!0)?string("##.##")}</td>
                                                <td>${(item.use_money!0)?string("##.##")}</td>
                                                <td>${(item.no_use_money!0)?string("##.##")}</td>
                                                <td>${item.wait_collect!0}</td>
                                                <td>${item.wait_repay!0}</td>
                                                <td>${(item.total-item.wait_repay)?string("##.##")}</td>
                                                <!-- v1.6.7.1 RDPROJECT-467 2013-11-19 start -->
												<td>${item.jin_wait_repay}</td>
												<!-- v1.6.7.1 RDPROJECT-467 2013-11-19 end -->
                                                <!-- v1.6.6.2 RDPROJECT-297 liukun 2013-10-22 begin -->
                                                <td><a href="/admin/cash/cashForbid.html?user_id=${(item.user_id!0)?c}">提现控制</a></td>
                                                <!-- v1.6.6.2 RDPROJECT-297 liukun 2013-10-22 end -->
                                            </tr>
                                        </#list>
                                         <tr>
                                         <!-- v1.6.7.1 RDPROJECT-434 zza 2013-11-13 start -->
                                         <td colspan="2">总余额：${accountSumModel.total!?string("##.##")}</td>
                                         <td colspan="2">总可用资金：${accountSumModel.use_money!?string("##.##")}</td>
                                         <td colspan="2">总冻结资金：${accountSumModel.no_use_money!?string("##.##")}</td>
                                         <td colspan="3">总可待收金额：${accountSumModel.collection!?string("##.##")}</td>
                                         <td colspan="3">总待还金额：${accountSumModel.wait_repay!?string("##.##")}</td>
                                         <!-- v1.6.7.1 RDPROJECT-434 zza 2013-11-13 end -->
                                         </tr>
                                    </table>
                                </form>

                                <!--底部工具栏--{-->
                                <div id="bottomToolbar" class="clearfix">
                                    <div class="other-tool">
                                        <dl class="refresh-data">
                                            <dt class="refresh-data-icon"></dt>
                                            <dd><a href="javascript:void(0);" class="refresh-page">刷新数据</a></dd>
                                        </dl>
                                    </div>

                                    <!--翻页系统--{-->
                                    <div class="container">
                                        <#import "../../common/page.html" as pager>
                                            <@pager.pagination page=page url="/admin/cash/showAllAccount.html" map=param style="style1" />
                                    </div>
                                    <!--翻页系统--}-->
                                </div>
                                <!--底部工具栏--}-->

                                <script>
                                    var url = 'showAllAccount.html?search=true';
                                    var xlsurl='showAllAccount.html?type=export'

                                    function sousuo(){
                                        var sou = "";
                                        var username = $("#username").val();
                                        if (username!=null&&username!=""&&username!="undefine"&&username!="请输入用户名"){
                                            sou += "&username="+username;
                                        }
                                        // v1.6.7.1 RDPROJECT-402 zza 2013-11-07 start
                                        var realname = $("#realname").val();
                                        if (realname!=null&&realname!=""&&realname!="undefine"&&realname!="请输入真实姓名"){
                                            sou += "&realname="+realname;
                                        }
                                    	 // v1.6.7.1 RDPROJECT-402 zza 2013-11-07 end
                                        if (sou!=""){
                                            location.href=url+sou;
                                        }
                                    }
                                    function exportxls(){
                                        var sou = "";
                                        var username = $("#username").val();
                                        if (username!=null&&username!=""&&username!="undefine"&&username!="请输入用户名"){
                                            sou += "&username="+username;
                                        }
                                     	// v1.6.7.1 RDPROJECT-402 zza 2013-11-07 start
                                        var realname = $("#realname").val();
                                        if (realname!=null&&realname!=""&&realname!="undefine"&&realname!="请输入真实姓名"){
                                            sou += "&realname="+realname;
                                        }
                                     	// v1.6.7.1 RDPROJECT-402 zza 2013-11-07 end
                                        if (sou!=""){
                                            location.href=xlsurl+sou;
                                        }else{
                                            location.href=xlsurl;
                                        }
                                    }
                                    
                                    $("#username").attr("value",getQueryString("username"));
                            		function getQueryString(name){
                            			var reg=new  RegExp("(^|&)"+name+"=([^&]*)(&|$)");
                            			var r =window.location.search.substr(1).match(reg);
                            			if(r!=null)
                            				return  unescape(r[2]);
                            			return  "请输入用户名";
                            		}
                                </script>
                            </div>

            </td>
        </tr>
        <tr>
            <!--尾部--{-->
            <td colspan="3" class="mc-b"><#include "../foot.html"></td>
            <!--尾部--}-->
        </tr>
    </table>

    </body>
</html>
<#include "../jsPage.html">
